import request from '@/utils/request'


export function getCompanies(params) {
  return request({
    url: '/api/Finance/CaseBillStas/GetCompanies',
    method: 'get',
    params
  })
}

export function getEmployees(params) {
  return request({
    url: '/api/Finance/CaseBillStas/GetEmployees',
    method: 'get',
    params
  })
}

export function getCaseBillAccountTypes() {
  return request({
    url: '/api/Finance/CaseBillStas/GetCaseBillAccountTypes',
    method: 'get',
  })
}

export function getCompanyCaseBills(params) {
  return request({
    url: '/api/Finance/CaseBillStas/GetCompanyCaseBills',
    method: 'get',
    params
  })
}

export function editBill(data) {
  return request({
    url: '/api/Finance/CaseBillStas/EditBill',
    method: 'post',
    data
  })
}

// export function addBillReturn (data) {
//   return request({
//     url: '/api/Finance/CaseBillStas/AddBillReturn',
//     method: 'post',
//     data
//   })
// }


export function deleteBillReturn(id) {
  return request({
    url: '/api/Finance/CaseBillStas/DeleteBillReturn',
    method: 'get',
    params: { id }
  })
}

export function refundBill(data) {
  return request({
    url: '/api/Finance/CaseBillStas/RefundBill',
    method: 'post',
    data
  })
}

export function reBill(data) {
  return request({
    url: '/api/Finance/CaseBillStas/ReBill',
    method: 'post',
    data
  })
}